<?php

    /**
     * @package      Modules
     * @subpackage   Languages_Classes_Db
	 *
     * @license      GNU Lesser General Public Licence see LICENCE-LGPL file or http://www.gnu.org/licenses/lgpl.html
     */
    class DbLanguage extends BaseDbLanguage
    {

    ////////////////////////////////////////////////////////////////////////////
	//                                Methods                                 //
	////////////////////////////////////////////////////////////////////////////

        /**
         * Converts code field to uppercase
         *
         * @param       Doctrine_Event  $event
         */
        public function preSave(Doctrine_Event $event)
        {
            $this->code = strtolower($this->code);
        }

        /**
         * __toString override
         *
         * @return      string
         */
        public function __toString()
        {
            return $this->name;
        }
    }